/**
 * 视频踩相关接口
 */
import request from '@/config/request'

/**
 * 获取视频踩数量
 */
export const getDislikeCount = (videoId: number) => {
  return request.get({ url: '/platform/video/dislike/getDislikeCount', params: { videoId } })
}

/**
 * 获取用户视频踩状态
 */
export const getDislikeStatus = (videoId: number) => {
  return request.get({ url: '/platform/video/dislike/getDislikeStatus', params: { videoId } })
}

/**
 * 踩视频
 */
export const saveDislike = (videoId: number) => {
  return request.post({ url: '/platform/video/dislike/saveDislike', params: { videoId } })
}

/**
 * 取消踩
 */
export const cancelDislike = (videoId: number) => {
  return request.delete({ url: '/platform/video/dislike/cancelDislike', params: { videoId } })
}
